package com.zhuhanpeng.cloud.file.entity;

import lombok.Data;

import java.io.Serializable;

@Data
public class SearchEntity implements Serializable {
    private Integer total;
    private Integer currentPage;
    private Integer pageSize;
    private Integer pageNum;
    private String searchInfo;
    private String[] searchInfoArray;
    private Object Data;

    public Integer getTotal() {
        return total;
    }

    public void setTotal(Integer total) {
        this.total = total;
    }

    public Integer getCurrentPage() {
        return currentPage;
    }

    public void setCurrentPage(Integer currentPage) {
        this.currentPage = currentPage;
    }

    public Integer getPageSize() {
        return pageSize;
    }

    public void setPageSize(Integer pageSize) {
        this.pageSize = pageSize;
    }

    public Integer getPageNum() {
        return pageNum;
    }

    public void setPageNum(Integer pageNum) {
        this.pageNum = pageNum;
    }

    public String getSearchInfo() {
        return searchInfo;
    }

    public void setSearchInfo(String searchInfo) {
        this.searchInfo = searchInfo;
    }

    public String[] getSearchInfoArray() {
        return searchInfoArray;
    }

    public void setSearchInfoArray(String[] searchInfoArray) {
        this.searchInfoArray = searchInfoArray;
    }

    public Object getData() {
        return Data;
    }

    public void setData(Object data) {
        Data = data;
    }

    public void setPage() {
        pageNum = (currentPage - 1) * pageSize;
    }

    public void setSearchInfoArray() {
        this.searchInfoArray = this.searchInfo.split(",|，");
    }
}
